package com.haoshuang.zhouzhoubang.ui.page.order.take.services

import com.haoshuang.zhouzhoubang.databinding.ItemChooseServiceLeftCateBinding
import com.haoshuang.zhouzhoubang.model.bean.ChooseServiceBean
import com.mufeng.libs.base.BaseBindingHolder
import com.mufeng.libs.base.BaseBindingQuickAdapter
import com.mufeng.libs.utils.view.visibleOrGone


/**
 *
 */
class ChooseServiceLeftCateAdapter(data: MutableList<ChooseServiceBean>) :
    BaseBindingQuickAdapter<ChooseServiceBean, ItemChooseServiceLeftCateBinding>(data) {
    override fun onBindViewHolder(
        holder: BaseBindingHolder,
        position: Int,
        item: ChooseServiceBean?
    ) {
        holder.getViewBinding<ItemChooseServiceLeftCateBinding>().apply {
            viewLine.visibleOrGone(item?.isSelect == true)
            tvTitle.isSelected = item?.isSelect == true
            tvTitle.text = item?.cate_name
        }
    }

}